<template>
  <TCollapse title="贴签信息">
    <el-form :model="prjDetail" label-width="160px" class="pms-form" size="mini" :inline="true">
      <el-row :gutter="24">
        <el-col :span="12">
          <el-form-item label="贴签位置" style="width: 100%" prop="labelLocation">
            <el-input v-model="prjDetail.labelLocation" class="pms-zr-input" :disabled="true"/>
          </el-form-item>
        </el-col>
        <el-col :span="6">
          <el-form-item label="贴签图片" style="width: 100%" prop="labelPhotoId">
              <div v-for="(item,index) in getImgUrl(prjDetail.labelPhotoId)" :key="index" style="position: relative">
                  <el-image
                      style="width: 50px; height: 50px;"
                      :src="item"
                      :preview-src-list="getImgUrl(prjDetail.labelPhotoId)">
                  </el-image>
              </div>
          </el-form-item>
        </el-col>
      </el-row>
      <div style="height: 25px"></div>
    </el-form>
  </TCollapse>
</template>

<script>

export default {
  name: 'MaterialInfo',
  props: {
    prjDetail: {
      type: Object,
      default: () => ({})
    }
  },
    methods:{
        getImgUrl(id){
            let arr=[]
            arr.push(window.location.protocol + "//" + window.location.host + "/pic/pic/openUrl?httpUrl="+ id)
            return arr;
        },
    }
}
</script>

<style scoped lang="scss">

</style>